With the introduction of a virtualization technology, a virtual machine (VM) may be dynamically created on and removed from a server or migrated between servers.
Generally, a user may create multiple VMs on a server; because the multiple VMs belong to the same user, the user may set general network policies corresponding to the multiple VMs and a personalized network policy, where the general network policies are the same for each VM created by the same user, for example, the multiple VMs belonging to the same user jointly comply with a group of access control list (ACL) policies.
However, according to the conventional method, in the case that a user has created a VM on the server, if the user wants to create a new VM on the same server, the server also needs to send network policy configuration information (including general network policy configuration information and personalized network policy configuration information) related to the newly created VM to a network device that communicates with the newly created VM, so that the network device configures a corresponding network policy for the newly created VM according to the network policy configuration information related to the newly created VM. Therefore, processing overheads are increased.